<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags"%>
<%	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
 %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>添加用户</title>
    <meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">
<script src="/oa/js/jquery-1.4.4.min.js"></script>
<script type="text/javascript">
    function checkPWD(){
		if($("#passWord1").val()!=$("#passWord").val()){
			$("#passWord1").val("");
			$("#passWord").val("");
			$("#passWord").focus();			
		}
	}
</script>
<style type="text/css">
		.errorMessage{
			color:red;
			font-size: 13px;
		}
		#x{ color:red; }
	</style>
  </head>
  <body style="text-align: center;margin: 0 auto; margin-top: 30px;">
  <h3>添加用户</h3>
   <s:form action="addUser"  validate="true" namespace="/page/permanage" >    
    <s:fielderror></s:fielderror>      
           <table>
           		<tr>
                	<td>
                	                  用户姓名：
                	</td>
                    <td >
                          <s:textfield name="user.userName" ></s:textfield>
                          <samp id="x">*</samp>
                    </td>
                </tr>
                 <tr>
                    <td>
                                                                          用户性别：
                    </td>
                    <td>
                           <s:radio list="#{'MAN':'男','WOMAN':'女'}" name="user.gender" ></s:radio>
                           <samp id="x">*</samp>
                    </td>
                </tr>
                <tr>
                	<td>
                	                用户密码 :
                	</td>
                    <td>
                           <s:password name="user.passWord" id="passWord"></s:password>
                           <samp id="x">*</samp>
                    </td>
                </tr>
                <tr>
                    <td>
                                                                     确认密码：
                    </td>
                    <td> 
                         <s:password id="passWord1" onBlur="checkPWD()"></s:password>
                    </td>
                </tr>
                <tr>
                  <td>
                                                                    所在部门：
                  </td>
                  <td>
                         <s:textfield name="user.depart"></s:textfield>
                         <samp id="x">*</samp>
                  </td>
                </tr>
                <tr>
                  <td>
                                                                 电话号码：
                  </td>
                  <td>
                        <s:textfield name="user.mobileTelNo"></s:textfield>
                        <samp id="x">*</samp>
                  </td>
                </tr>
                <tr>
                  <td>
                                                                角色赋予：
                  </td>
                  <td>    
                        <s:checkboxlist name="sdfsd" list="roles" listKey="roleId" listValue="name" ></s:checkboxlist>
                        <samp id="x">*</samp>
                  </td>
                </tr>
                <tr>
                  <td>
                                                               状态：
                  </td>
                  <td>
                        <s:textfield name="user.state"></s:textfield>
                        <samp id="x">*</samp>
                  </td>
                </tr>
                <tr>
                  <td>
                                                               备注：
                  </td>
                  <td>
                        <s:textarea name="user.remark"></s:textarea>
                  </td>
                </tr>
                <tr>
                  <td>
                        <input type="submit" value="添加" />
                  </td>
                  <td>
                        <input type="reset" value="重置" />
                  </td>
                </tr>
           </table>
    </s:form>
  </body>
</html>
